<?php
/**
 * Created by PhpStorm.
 * User: zhan
 * Date: 2017/11/10  13:38
 */
namespace app\api\controller;
class Order extends Base{
    //检查权限作用域
    protected $beforeActionList  = [
        'checkPrimaryScope' => [
            'except' => ''
        ],
    ];
    /**
     * 订单列表
     */
    public function index()
    {
        $result =  (new \app\api\logic\Order())->index();
        return $this->ajaxReturn($result);
    }
    /**
     * 订单详情
     */
    public function detail()
    {
        $result =  (new \app\api\logic\Order())->detail();
        return $this->ajaxReturn($result);
    }
    /**
     * 预订门票
     */
    public function create_ticket()
    {
        $result =  (new \app\api\logic\Order())->create_ticket();
        return $this->ajaxReturn($result);
    }
    /**
     * 预订房间
     */
    public function create_room()
    {
        $result =  (new \app\api\logic\Order())->create_room();
        return $this->ajaxReturn($result);
    }
    /**
     * 预订套票
     */
    public function create_package()
    {
        $result =  (new \app\api\logic\Order())->create_package();
        return $this->ajaxReturn($result);
    }

    /**
     * 取消订单
     */
    public function cancel()
    {
        $result =  (new \app\api\logic\Order())->cancel();
        return $this->ajaxReturn($result);
    }
    /**
     * 删除订单
     */
    public function delete()
    {
        $result =  (new \app\api\logic\Order())->delete();
        return $this->ajaxReturn($result);
    }
    /**
     * 申请退款
     */
    public function refund()
    {
        $result =  (new \app\api\logic\Order())->refund();
        return $this->ajaxReturn($result);
    }

    /**
     * 二维码
     */
    public function qrcode()
    {
        $result =  (new \app\api\logic\Order())->qrcode();
        return $this->ajaxReturn($result);
    }
    /**
     * 确认入住
     */
    public function check()
    {
        $result =  (new \app\api\logic\Order())->check();
        return $this->ajaxReturn($result);
    }
}